<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        #template {
            display: none
        }
    </style>
</head>
<body>
    <div id="template">
        <h1 @click="add" v-once>{{count}}</h1>
    </div>
    <div id="app"></div>
    <script src="../../../../packages/vue/dist/vue.global.js"></script>

    <script>
        const { createApp, ref } = Vue

        const template = document.querySelector('#template')?.innerHTML
        const App = {
            setup() {
                const count = ref(0)
                const add = () => count.value++
                return {
                    count,
                    add
                }
            },
            template
        }

        createApp(App).mount('#app')
    </script>

</body>
</html>